// ----------------------------------------------
// imports
// ----------------------------------------------
import org.apache.log4j.PropertyConfigurator;
import controlP5.*;
import gml4u.brushes.*;
import gml4u.recording.*;
import gml4u.utils.*;
import gml4u.drawing.*;
import gml4u.events.*;
import gml4u.model.*;
import gml4u.model.Gml;
import toxi.geom.*;
import processing.opengl.*;

Tool tool;

// ----------------------------------------------
// setup
// ----------------------------------------------
void setup()
{
  size(screen.width, screen.height, OPENGL);
  PropertyConfigurator.configure(sketchPath+"/log4j.properties");
  
  tool = new Tool(this);
  tool.createControls();
  tool.loadFont();
}

// ----------------------------------------------
// draw
// ----------------------------------------------
void draw(){
  background(0);
  tool.draw();
  tool.drawControls();
}

// ----------------------------------------------
// mousePressed
// ----------------------------------------------
void mousePressed() {
  tool.mousePressed();
}

// ----------------------------------------------
// mouseDragged
// ----------------------------------------------
void mouseDragged() {
  tool.mouseDragged();
}

// ----------------------------------------------
// mouseReleased
// ----------------------------------------------
void mouseReleased() {
  tool.mouseReleased();
}

// ----------------------------------------------
// keyPressed
// ----------------------------------------------
void keyPressed() {
  tool.keyPressed();
}

